<input type="hidden" name="edit_attach_ids" />
 <input type="hidden" name="delete_attach" />
 <input type="hidden" name="total_files" id="total_files" />

<div class="genmed" tblAttachments" >
<div class="genmed">
<span class="gensmall">
  <b>${I18n.getMessage("Attachments.maxToAttach")}:</b> ${maxAttachments}
  <#assign maxSize = maxAttachmentsSize / 1024>
  <#if (maxSize > 1)>
   /
   <b>${I18n.getMessage("Attachments.maxSize")}:</b> <font color="red">${maxSize} kb</font>
  </#if>
  </span>
  </div>
<div class="genmed">
<div id="edit_attach"></div>
  <div id="attachmentFields"></div>
</div>
<#if attachmentsEnabled>
<div class="genmed">
  <input type="button" name="add_attach" value="${I18n.getMessage("PostForm.AddAnotherFile")}" class="mainoption" onclick="addAttachmentFields()" />
  </div>
      <#if !attachments?exists>
  <script type="text/javascript">addAttachmentFields();</script>
   </#if>
  </#if>
</div>